# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=retro-gtk
pkgver=0.18.1
pkgrel=1
pkgdesc="The GTK+ Libretro frontend framework"
url="https://gitlab.gnome.org/GNOME/retro-gtk"
arch="all"
license="GPL-3.0-or-later"
makedepends="meson libepoxy-dev glib-dev gtk+3.0-dev pulseaudio-dev
	gobject-introspection-dev vala"
checkdepends="xvfb-run"
subpackages="$pkgname-dev"
source="https://download.gnome.org/sources/retro-gtk/${pkgver%.*}/retro-gtk-$pkgver.tar.xz"

build() {
	meson \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
		--buildtype=plain \
		. output
	ninja -C output
}

check() {
	xvfb-run ninja -C output test
}

package() {
	DESTDIR="$pkgdir" ninja -C output install
}

sha512sums="9a35f0681f7e1f1491b7ddf4eac23bbdcd6f109e06056ec0ffbe6cd0f9e949296c7b2cad88b5fb6bbb68e9a8f0698bc23b2304d91f3d55cb9dd79ac28bcd7494  retro-gtk-0.18.1.tar.xz"
